package com.dp.exception;

/**
 * @author:defuzhu
 * bean 没找到异常类
 */
public class NotFountBeanException extends RuntimeException{


    private static final long serialVersionUID = 1L;

    private static final String ERROR_CODE_500 = "500";
    private static final String ERROR_MESSAGE_500 = "系统异常";


    /**
     * 错误异常业务码
     */
    private String code;

    private String errorMsg;


    public NotFountBeanException(String errorMsg) {
        super(errorMsg);
        this.code = ERROR_CODE_500;
        this.errorMsg = errorMsg;
    }


    public NotFountBeanException(String errorMsg, String code) {
        super(errorMsg);
        this.code = code;
        this.errorMsg = errorMsg;
    }

    public NotFountBeanException(String errorMsg, Throwable cause, String code) {
        super(errorMsg, cause);
        this.code = code;
        this.errorMsg = errorMsg;
    }

    public NotFountBeanException(Throwable cause, String code) {
        super(cause);
        this.code = code;
        this.errorMsg = ERROR_MESSAGE_500;
    }
}
